package com.qianf.qfoffice.service.impl;

import com.qianf.qfoffice.dao.CourseDao;
import com.qianf.qfoffice.entity.Course;
import com.qianf.qfoffice.service.CourseService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CourseServiceImpl implements CourseService {

    @Autowired
    private CourseDao courseDao;

    @Override
    public List<Course> findAllCourse() {
        return courseDao.findAllCourse();
    }

    @Override
    public int deleteCourseById(int id) {
        return courseDao.deleteCourseById(id);
    }

    @Override
    public int updateCourse(Course course) {
        return courseDao.updateCourse(course);
    }

    @Override
    public int addCourse(Course course) {
        return courseDao.addCourse(course);
    }
}
